package com.xxx.demo.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.xxx.demo.dto.GuestBookDto;
import com.xxx.demo.entity.GuestBook;
import com.xxx.demo.entity.News;
import com.xxx.demo.vo.GuestBookVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
* @author 562702
* @description 针对表【guest_book_table】的数据库操作Mapper
* @createDate 2023-03-27 16:16:10
* @Entity generator.domain.GuestBook
*/
public interface GuestBookMapper extends BaseMapper<GuestBook> {

    /**
     * 查询所有留言
     * @return
     */
    List<GuestBookVo> selectGuestBook();


    /**
     * 根据id查询留言
     * @param id
     * @return
     */
    GuestBook selectGuestBookById(Long id);

    IPage<GuestBookVo> selectGuestBookPage(Page<GuestBookVo> page, @Param("guestbook") GuestBookDto guestBook);
}




